﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Seagull.Foundation
{
    /// <summary>
    /// 
    /// </summary>
    public class ServiceBusInvocationContext
    {
        public ServiceBusInvocationContext(string name, object? content, IDictionary<string, string?>? headers)
        {
            Name = name;
            Content = content;
            Headers = headers ?? new Dictionary<string, string?>();
        }

        /// <summary>
        /// 处理程序的标识符
        /// </summary>
        public string Name { get; }

        /// <summary>
        /// 将被序列化的消息正文内容。(可以为空)
        /// </summary>
        public object? Content { get; }

        /// <summary>
        /// 消息附加头。
        /// </summary>
        public IDictionary<string, string?>? Headers { get; }
    }
}
